package com.example.brazil_project.function;

import com.example.brazil_project.DucumentActivity;
import com.example.brazil_project.DucumentDetailActivity;
import com.example.brazil_project.UpdateProfileActivity;

import android.app.Activity;
import android.content.Context;
import android.content.Intent;
import android.webkit.WebView;

public class IndexFunction {
	Activity mContxt;  
	WebView webview;
	 public IndexFunction(Activity mContxt,WebView webview) {  
	        this.mContxt = mContxt;
	        this.webview = webview;
	       
	  }  
	 public String goDud(String du_id){
		 Intent intent = new Intent(mContxt, DucumentDetailActivity.class);
		 intent.putExtra("du_id", du_id);
		 mContxt.startActivity(intent);
		 
		 return "1";
	 }
	 
	 //展示详情
	 public void showInfo(String orientation){
		 String url = "javascript:shouinfo('"+orientation+"')";
		 webview.loadUrl(url);
	 }
	 
	 /**
	  * 跳转修改用户资料的界面
	  */
	 public void gotoupdateprofile(){
		 Intent intent = new Intent(mContxt, UpdateProfileActivity.class);
		 mContxt.startActivity(intent);
		 
	 }
	 
	
	
}
